import { DataSource } from "typeorm";
import { Article } from "./article/entities/article.entity";        
import { LoginUser } from "./login-user/entities/login-user.entity";
import { Permission } from "./login-user/entities/permission.entity";


export default new DataSource({
    type: "mysql",
    host: "localhost",
    port: 3305,
    username: "root",
    password: "111111",
    // database: "nest-migration-test", 
    database: "login_test",
    synchronize: false,
    logging: true,
    // entities: [Article],
    entities: [LoginUser, Permission],
    poolSize: 10,
    migrations: ['src/migrations/**.ts'],
    connectorPackage: 'mysql2',
    extra: {
        authPlugin: 'sha256_password',
    }
});
